/*
 * Sesame Inc.
 * Copyright (c) 2009 All Rights Reserved.
 */
package com.sesame.dao;

import java.util.List;

import com.sesame.domain.Message;
import com.sesame.toolkit.Page;

/**
 * @author shubeta
 * 
 */
public interface MessageDAO {
    public List<Message> getAllMessage();

    public Message getMessageById(Integer id);

    public List<Message> getMessageByReceiver(Page page);

    public List<Message> getMessageBySender(Page page);

    public void addMessage(Message message);

    public void deleteMessageById(Integer id);

    public void deleteMessageByState(char state);

    public void updateMessage(Message message);

    public Integer getMessageCount();

    public Integer getSendedMessageCount(Integer senderId);

    public Integer getReceivedMessageCount(Integer receiverId);

}